home *** CD-ROM | disk | FTP | other *** search
/ Aminet 41 / Aminet 41 (2001)(Schatztruhe)[!][Feb 2001].iso / Aminet / gfx / edit / AmiCAD_2.07.lha / AmiCAD / Install English < prev    next >
Text File  |  2000-12-10  |  13KB  |  386 lines

  1. ;----------------------------------------------------------------------------
  2. ; Installation script for AmiCAD
  3. ;
  4. ; $VER: AmiCAD-Install 1.3 (06.05.98)
  5. ;
  6. ; (C)1997-1998 R.Florac
  7.  
  8. ;****************************************************************************
  9. ; Creation of the AmiCAD drawer *********************************************
  10. ;****************************************************************************
  11. (set #AmiCADdestdir-help "A directory named AmiCAD will be created, if it doesn't allready exists, at the place you'll choose")
  12.  
  13. (set #destination
  14.     (expandpath
  15.     (askdir
  16.         (prompt "Where do you want to install the AmiCAD drawer?")
  17.         (help #AmiCADdestdir-help)
  18.         (default @default-dest)
  19.         (disk)
  20.     )
  21.     )
  22. )
  23.  
  24. (set @default-dest (tackon #destination "AmiCAD"))
  25.  
  26. (if (= 0 (askbool
  27.     (prompt "Destination directory for AmiCAD\nwill be "@default-dest)
  28.     (choices "Continue" "Stop")
  29.     (help "If the specified directory doesn't agree, choose 'Stop': you'll have to restart this installer script and choose another directory for destination.")
  30.     ))
  31.     (exit (quiet))
  32. )
  33.  
  34. (if (= (exists @default-dest (noreq)) 0) (makedir @default-dest (infos)))
  35. (makedir (tackon @default-dest "Library"))
  36. (makedir (tackon @default-dest "Sheets") (infos))
  37. (makedir (tackon @default-dest "Clips"))
  38. (makedir (tackon @default-dest "ARexx"))
  39. (makedir (tackon @default-dest "ToolBars"))
  40.  
  41. ;****************************************************************************
  42. ; Copy of the AmiCAD files **************************************************
  43. ;****************************************************************************
  44. (copyfiles
  45.     (source "")
  46.     (dest @default-dest)
  47.     (pattern "AmiCAD#?")
  48.     (prompt "Choose the files you want to copy")
  49.     (help (cat "Select the files you want to copy, only the marked files will be copied.\nAmiCAD is the program file.\nAmiCAD.keys is the file where you are stored the definitions of macros keys.\n"
  50.     "AmiCAD.prefs is the file where are stored the preferences, don't copy it if you want to keep your old preferences."))
  51.     (confirm)
  52.     (infos)
  53. )
  54.  
  55. (delete (tackon @default-dest "AmiCAD.prefs"))
  56. (copyfiles
  57.     (source "prefs.english")
  58.     (dest @default-dest)
  59. )
  60. (rename (tackon @default-dest "prefs.english") (tackon @default-dest "AmiCAD.prefs"))
  61.  
  62. ;****************************************************************************
  63. ; Copy of the AmiCAD libraries (symbols files) ******************************
  64. ;****************************************************************************
  65. (copyfiles
  66.     (source "Bibliothèques")
  67.     (dest (tackon @default-dest "Library"))
  68.     (pattern "#?")
  69.     (prompt "Choose the symbols files to copy\nSome files has been updated.")
  70.     (help "Select the files you want to copy, they are symbols files, AmiCAD use them to draw schematics.\nA new library has been created (opto-electronic), some others has been enhanced.")
  71.     (confirm)
  72.     (infos)
  73. )
  74.  
  75. ;****************************************************************************
  76. ; Copy of the AmiCAD clips **************************************************
  77. ;****************************************************************************
  78. (copyfiles
  79.     (source "Clips_english")
  80.     (dest (tackon @default-dest "Clips"))
  81.     (pattern "#?")
  82.     (prompt "Choose the clip files to copy")
  83.     (help "Select the files you want to copy, they are clip files, defined with AmiCAD.\nThey can be used to draw some current symbols not yet defined in the libraries.\nYou shall be able to define your own clips with AmiCAD.")
  84.     (confirm)
  85.     (infos)
  86. )
  87.  
  88. ;****************************************************************************
  89. ; Copy of the AmiCAD ARexx scripts ******************************************
  90. ;****************************************************************************
  91. (copyfiles
  92.     (source "ARexx")
  93.     (dest (tackon @default-dest "ARexx"))
  94.     (pattern "#?")
  95.     (prompt "Choose the ARexx scripts you want to copy\nWARNING: all the scripts have been greatly enhanced, they are now localized.")
  96.     (help "Select the files you want to copy.\nThe contents of this files are macro-commands, they can be used with AmiCAD.")
  97.     (confirm)
  98.     (infos)
  99. )
  100.  
  101. ;****************************************************************************
  102. ; Copy of the AmiCAD sheet files ********************************************
  103. ;****************************************************************************
  104. (copyfiles
  105.     (source "Schémas")
  106.     (dest (tackon @default-dest "Sheets"))
  107.     (pattern "#?")
  108.     (prompt "Choose the sheets files you want to copy\n")
  109.     (help "Select the files you want to copy, they are examples files obtained with AmiCAD.")
  110.     (confirm)
  111.     (infos)
  112. )
  113.  
  114. ;****************************************************************************
  115. ; Setting the tooltypes of the AmiCAD icon **********************************
  116. ;****************************************************************************
  117. (tooltype
  118.     (prompt "Setting AmiCAD LIBS Tooltypes")
  119.     (dest (tackon @default-dest "AmiCAD"))
  120.     (settooltype "LIBS" (tackon @default-dest "library"))
  121. )
  122.  
  123. (tooltype
  124.     (prompt "Setting AmiCAD CLIPS Tooltype")
  125.     (dest (tackon @default-dest "AmiCAD"))
  126.     (settooltype "CLIPS" (tackon @default-dest "Clips"))
  127. )
  128.  
  129. (tooltype
  130.     (prompt "Setting AmiCAD HELPFILE Tooltype")
  131.     (dest (tackon @default-dest "AmiCAD"))
  132.     (settooltype "HELPFILE" (tackon @default-dest "AmiCAD.guide"))
  133. )
  134.  
  135. (set msg_welcome "IF(OBJECTS(-1)==0,LOAD(\"Sheets/Logo\"),0):MESSAGE(\"Welcome with AmiCAD\"+CHR(10)+\"the electronics editor\"+CHR(10)+\"for Amiga computer.\")")
  136. (tooltype
  137.     (prompt "Set AmiCAD Macro Tooltypes")
  138.     (dest (tackon @default-dest "AmiCAD"))
  139.     (settooltype "MACRO" msg_welcome)
  140. )
  141.  
  142. ;****************************************************************************
  143. ; Copy of the AmiCAD.guide file *********************************************
  144. ;****************************************************************************
  145. (set catalogue 1)
  146. (if (= @language "français") (set catalogue 0))
  147.  
  148. (set catalogues
  149.     (askchoice
  150.         (prompt "Select the guide you want to install")
  151.         (help "The english guide is not yet finished but it has been enhanced, all ARexx functions are now correctly descripted.")
  152.         (choices "Français" "English")
  153.         (default catalogue)
  154.     )
  155. )
  156.  
  157. (if (= catalogues 0)
  158.     (copyfiles
  159.     (prompt "Copying the french guide")
  160.     (source ("docs/français"))
  161.     (dest (@default-dest))
  162.     (all)
  163.     )
  164. )
  165.  
  166. (if (= catalogues 1)
  167.     (copyfiles
  168.     (prompt "Copying the english guide")
  169.     (source ("docs/english"))
  170.     (dest (@default-dest))
  171.     (all)
  172.     )
  173. )
  174.  
  175. ;****************************************************************************
  176. ; Copy of the AmiCAD catalogs ***********************************************
  177. ;****************************************************************************
  178. (set catalogue 32)
  179. (if (= @language "français") (set catalogue 1))
  180. (if (= @language "deutsch") (set catalogue 2))
  181. (if (= @language "ÃeÓtina") (set catalogue 4))
  182. (if (= @language "español") (set catalogue 8))
  183. (if (= @language "italiano") (set catalogue 16))
  184. (if (= @language "slovensko") (set catalogue 64))
  185. (if (= @language "Suomi") (set catalogue 128))
  186. (if (= @language "Svenska") (set catalogue 256))
  187.  
  188. (set catalogues
  189.     (askoptions
  190.         (prompt "Select the catalog you want to install")
  191.         (help "The catalog of your country is the one you have to copy.\nThe english catalogs are for library files.\nSome library catalogs have been written.\nMany catalogs have not been updated.")
  192.         (choices "Français" "Deutsch" "Czech" "Español" "Italiano" "English" "Slovensko" "Suomi" "Svenska")
  193.         (default catalogue)
  194.     )
  195. )
  196.  
  197. (if (= (BITAND catalogues 1) 1)
  198.     (   (makedir (tackon @default-dest "Catalogs"))
  199.     (copyfiles
  200.         (prompt "Copying the french catalog")
  201.         (source ("Catalogs/français"))
  202.         (dest   (tackon @default-dest "catalogs/français"))
  203.         (all)
  204.     )
  205.     )
  206. )
  207.  
  208. (if (= (BITAND catalogues 2) 2)
  209.     (   (makedir (tackon @default-dest "Catalogs"))
  210.     (copyfiles
  211.         (prompt "Copying the deutsch catalog")
  212.         (source ("Catalogs/deutsch"))
  213.         (dest   (tackon @default-dest "catalogs/deutsch"))
  214.         (all)
  215.     )
  216.     )
  217. )
  218.  
  219. (if (= (BITAND catalogues 4) 4)
  220.     (   (makedir (tackon @default-dest "Catalogs"))
  221.     (copyfiles
  222.         (prompt "Copying the czech catalog")
  223.         (source ("Catalogs/ÃeÓtina"))
  224.         (dest   (tackon @default-dest "catalogs/ÃeÓtina"))
  225.         (all)
  226.     )
  227.     )
  228. )
  229.  
  230. (if (= (BITAND catalogues 8) 8)
  231.     (   (makedir (tackon @default-dest "Catalogs"))
  232.     (copyfiles
  233.         (prompt "Copying the spanish catalog")
  234.         (source ("Catalogs/español"))
  235.         (dest   (tackon @default-dest "catalogs/español"))
  236.         (all)
  237.     )
  238.     )
  239. )
  240.  
  241. (if (= (BITAND catalogues 16) 16)
  242.     (   (makedir (tackon @default-dest "Catalogs"))
  243.     (copyfiles
  244.         (prompt "Copying the italian catalogs")
  245.         (source ("Catalogs/italiano"))
  246.         (dest   (tackon @default-dest "catalogs/italiano"))
  247.         (all)
  248.     )
  249.     )
  250. )
  251.  
  252. (if (= (BITAND catalogues 32) 32)
  253.     (   (makedir (tackon @default-dest "Catalogs"))
  254.     (copyfiles
  255.         (prompt "Copying the english catalogs")
  256.         (source ("Catalogs/english"))
  257.         (dest   (tackon @default-dest "catalogs/english"))
  258.         (all)
  259.     )
  260.     )
  261. )
  262.  
  263. (if (= (BITAND catalogues 64) 64)
  264.     (   (makedir (tackon @default-dest "Catalogs"))
  265.     (copyfiles
  266.         (prompt "Copying the slovenian catalogs")
  267.         (source ("Catalogs/slovensko"))
  268.         (dest   (tackon @default-dest "catalogs/slovensko"))
  269.         (all)
  270.     )
  271.     )
  272. )
  273.  
  274. (if (= (BITAND catalogues 128) 128)
  275.     (   (makedir (tackon @default-dest "Catalogs"))
  276.     (copyfiles
  277.         (prompt "Copying the Suomi catalogs")
  278.         (source ("Catalogs/Suomi"))
  279.         (dest   (tackon @default-dest "catalogs/Suomi"))
  280.         (all)
  281.     )
  282.     )
  283. )
  284.  
  285. (if (= (BITAND catalogues 256) 256)
  286.     (   (makedir (tackon @default-dest "Catalogs"))
  287.     (copyfiles
  288.         (prompt "Copying the Svenska catalogs")
  289.         (source ("Catalogs/Svenska"))
  290.         (dest   (tackon @default-dest "catalogs/Svenska"))
  291.         (all)
  292.     )
  293.     )
  294. )
  295.  
  296. ;****************************************************************************
  297. ; Copy of the catalogs sources **********************************************
  298. ;****************************************************************************
  299. (set catalogues
  300.     (askbool
  301.         (prompt "Do you want to copy the catalog sources files?")
  302.         (help "The sources files of the catalog are only needed if you want to create a catalog file for a new country (not yet done).")
  303.         (default 0)
  304.     )
  305. )
  306.  
  307.  
  308. (if (= catalogues 1)
  309.     (   (set sources
  310.         (askoptions
  311.         (prompt "Select the catalogs sources you want to install")
  312.         (help "The sources files of the catalog are only needed if you want to create a catalog file for a new country (not yet done).")
  313.         (choices "French" "Deutsch" "Czech" "Italiano" "english")
  314.         (default catalogue)
  315.         )
  316.     )
  317.     (if (= (BITAND sources 1) 1)
  318.         (   (makedir (tackon @default-dest "Catalogs"))
  319.         (copyfiles
  320.             (prompt "Copying the french source catalog")
  321.             (source ("Catalogs"))
  322.             (pattern ("#?.(français.ct|cd)"))
  323.             (dest   (tackon @default-dest "catalogs"))
  324.             (files)
  325.         )
  326.         )
  327.     )
  328.     (if (= (BITAND sources 2) 2)
  329.         (   (makedir (tackon @default-dest "Catalogs"))
  330.         (copyfiles
  331.             (prompt "Copying the deutsch source catalog")
  332.             (source ("Catalogs"))
  333.             (pattern ("#?.(deutsch.ct|cd)"))
  334.             (dest   (tackon @default-dest "catalogs"))
  335.             (files)
  336.         )
  337.         )
  338.     )
  339.     (if (= (BITAND sources 4) 4)
  340.         (   (makedir (tackon @default-dest "Catalogs"))
  341.         (copyfiles
  342.             (prompt "Copying the czech source catalog")
  343.             (source ("Catalogs"))
  344.             (pattern ("#?.(ÃeÓtina.ct|cd)"))
  345.             (dest   (tackon @default-dest "catalogs"))
  346.             (files)
  347.         )
  348.         )
  349.     )
  350.     (if (= (BITAND sources 8) 8)
  351.         (   (makedir (tackon @default-dest "Catalogs"))
  352.         (copyfiles
  353.             (prompt "Copying the italian source catalog")
  354.             (source ("Catalogs"))
  355.             (pattern ("#?.(italiano.ct|cd)"))
  356.             (dest   (tackon @default-dest "catalogs"))
  357.             (files)
  358.         )
  359.         )
  360.     )
  361.     (if (= (BITAND sources 16) 16)
  362.         (   (makedir (tackon @default-dest "Catalogs"))
  363.         (copyfiles
  364.             (prompt "Copying the english source catalogs")
  365.             (source ("Catalogs"))
  366.             (pattern ("#?.(english.ct|cd)"))
  367.             (dest   (tackon @default-dest "catalogs"))
  368.             (files)
  369.         )
  370.         )
  371.     )
  372.     )
  373. )
  374.  
  375. ;****************************************************************************
  376. ; Copy of toolbars **********************************************************
  377. ;****************************************************************************
  378. (copyfiles
  379.     (prompt "Copying toolbars")
  380.     (source ("barres"))
  381.     (dest (tackon @default-dest "ToolBars"))
  382.     (all)
  383. )
  384.  
  385. (exit)
  386.